package com.ruoyi.system.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.T3rdwarehouseMapper;
import com.ruoyi.system.domain.T3rdwarehouse;
import com.ruoyi.system.service.IT3rdwarehouseService;

/**
 * 第三方仓库信息Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-05-15
 */
@Service
public class T3rdwarehouseServiceImpl implements IT3rdwarehouseService 
{
    @Autowired
    private T3rdwarehouseMapper t3rdwarehouseMapper;

    /**
     * 查询第三方仓库信息
     * 
     * @param warehouseId 第三方仓库信息主键
     * @return 第三方仓库信息
     */
    @Override
    public T3rdwarehouse selectT3rdwarehouseByWarehouseId(String warehouseId)
    {
        return t3rdwarehouseMapper.selectT3rdwarehouseByWarehouseId(warehouseId);
    }

    /**
     * 查询第三方仓库信息列表
     * 
     * @param t3rdwarehouse 第三方仓库信息
     * @return 第三方仓库信息
     */
    @Override
    public List<T3rdwarehouse> selectT3rdwarehouseList(T3rdwarehouse t3rdwarehouse)
    {
        return t3rdwarehouseMapper.selectT3rdwarehouseList(t3rdwarehouse);
    }

    /**
     * 新增第三方仓库信息
     * 
     * @param t3rdwarehouse 第三方仓库信息
     * @return 结果
     */
    @Override
    public int insertT3rdwarehouse(T3rdwarehouse t3rdwarehouse)
    {
        t3rdwarehouse.setCreateTime(DateUtils.getNowDate());
        return t3rdwarehouseMapper.insertT3rdwarehouse(t3rdwarehouse);
    }

    /**
     * 修改第三方仓库信息
     * 
     * @param t3rdwarehouse 第三方仓库信息
     * @return 结果
     */
    @Override
    public int updateT3rdwarehouse(T3rdwarehouse t3rdwarehouse)
    {
        t3rdwarehouse.setUpdateTime(DateUtils.getNowDate());
        return t3rdwarehouseMapper.updateT3rdwarehouse(t3rdwarehouse);
    }

    /**
     * 批量删除第三方仓库信息
     * 
     * @param warehouseIds 需要删除的第三方仓库信息主键
     * @return 结果
     */
    @Override
    public int deleteT3rdwarehouseByWarehouseIds(String[] warehouseIds)
    {
        return t3rdwarehouseMapper.deleteT3rdwarehouseByWarehouseIds(warehouseIds);
    }

    /**
     * 删除第三方仓库信息信息
     * 
     * @param warehouseId 第三方仓库信息主键
     * @return 结果
     */
    @Override
    public int deleteT3rdwarehouseByWarehouseId(String warehouseId)
    {
        return t3rdwarehouseMapper.deleteT3rdwarehouseByWarehouseId(warehouseId);
    }
}
